<!-- Basic UI for running the demo in the browser -->

<html>
<head>
  <title>Sum integers under MPC</title>
  <style>
    .error {
      color: #FF0000;
    }
  </style>
  <script src="/config.js"></script>

  <script src="https://code.jquery.com/jquery-1.11.1.js"></script>
  <script src="/dist/jiff-client.js"></script>
  <script src="/lib/ext/jiff-client-restful.js"></script>

  <!-- Contains UI Handlers and Input Checks -->
  <script type="text/javascript" src="./client.js"></script>

  <!-- Contains Client MPC code -->
  <script type="text/javascript" src="./client-mpc.js"></script>
</head>
<body>
  <h1>Connect JIFF</h1>
  <label for="computation_id">Computation ID</label><input id="computation_id" value="test"/><br/><br/>
  <button id="connectButton" onclick="connect();">Connect</button>
  <br/><br/>
  <hr/>
  <h1>Sum Numbers under MPC as a service</h1>
  <label for="number">Input Number (between 0 and 100)</label> <input id="number" pattern="[0-9]+"> &nbsp; <button onclick="submit();" disabled="disabled" id="button">Sum</button><br/>
  <div id="output"></div>
</body>
</html>
